package com.ruoyi.crop.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.security.utils.SecurityUtils;
import com.ruoyi.crop.api.domain.Check;
import com.ruoyi.crop.api.domain.Crop;
import com.ruoyi.crop.service.CheckService;
import com.ruoyi.crop.mapper.CheckMapper;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
* @author 86178
* @description 针对表【src_check(质检表)】的数据库操作Service实现
* @createDate 2024-07-27 09:35:55
*/
@Service
public class CheckServiceImpl extends ServiceImpl<CheckMapper, Check>
    implements CheckService{

    @Override
    public List<Check> selectCheckList(Check check) {
        List<Check>  checkList = null;
        if(SecurityUtils.getUserId()==1){
            checkList = baseMapper.selectCheckList(check);
        }else{
            checkList = baseMapper.selectCheckListByZjId(check,check.getZjId());
        }
        return checkList;
    }


}




